#include <stdio.h>

template <int i, int j>
struct Add 
{
    enum {value = i+ j};
};


template<typename T>
auto  visitall(T& func)
{
    int arr[] = {1,2,3,4};
    for(auto var: arr)
    {
        if(func(var)) return true;
    }
    return func(0);
}

struct base
{
    void baseFucn()
    {}
};

template<typename T>
struct test:base
{
    void tryComplte(int a, int b)
    {
    }
};
int main()
{
    auto i = "xxx";
    int  x = 2;
    auto func = [](int x){return x +1;};
    
    printf("%d\n", func(x));

    auto printFunc = [x](int var){printf("hahah = %d", var); return x;};
    auto boolFunc = [&x](auto var){printf("hahah = %d", var);
                                 return var ==x;};

	auto y = printFunc(1);
    printf("result is %d \n", Add<2, 4>::value);
    printf("%s\n",i); 
    printf("%d\n",x); 
}
